%% Sample scale conductivities in the ordered and disordered geometries
clear all; close all;
%%%%%%%%%%%%%%%%%%%% root
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
root = 'D:\';
%%%%%%%%%%
load([root,'Compilation DiodeNatCom\figure 4\SampleScaleCond.mat']);

forward_HD = 3;
trapped_HD = 13;
breakdown_HD = 26;

forward_HO = 5;
trapped_HO = 9;
breakdown_HO = 15;


close all;
margin = 0.1;
u = 2;
a = 2*u;
b = 2*u;
hFig = figure('color',[1,1,1],'Units','centimeter','Position',[4,4,a+1.1*margin,b+1.1*margin]); 
ax = axes('Units','centimeters');
ax.Position = [.5*margin,.5*margin, a, b];
box on;
hold on;
plot([-8,1],0*[-8,1],'--k');
plot(0*[-1.75,1],[-1.75,1],'--k');

plot(SampleScaleCond(1).x,SampleScaleCond(1).y,'LineWidth',1,'color',[0,0,1]);
plot(SampleScaleCond(2).x,SampleScaleCond(2).y,'LineWidth',1,'color',[1,0,0]);

% marks in 0.5, 0 and -0.5
plot(SampleScaleCond(1).x([forward_HD]),SampleScaleCond(1).y([forward_HD]),'o','color',[0,0.25,1],'MarkerFaceColor','w','LineWidth',1.2);
plot(SampleScaleCond(1).x([trapped_HD]),SampleScaleCond(1).y([trapped_HD]),'o','color',[0,0.5,1],'MarkerFaceColor','w','LineWidth',1.2);
plot(SampleScaleCond(1).x([breakdown_HD]),SampleScaleCond(1).y([breakdown_HD]),'o','color',[0,0.75,1],'MarkerFaceColor','w','LineWidth',1.2);

plot(SampleScaleCond(2).x([forward_HO]),SampleScaleCond(2).y([forward_HO]),'o','color',[1,0.25,0],'MarkerFaceColor','w','LineWidth',1.2);
plot(SampleScaleCond(2).x([trapped_HO]),SampleScaleCond(2).y([trapped_HO]),'o','color',[1,0.5,0],'MarkerFaceColor','w','LineWidth',1.2);
plot(SampleScaleCond(2).x([breakdown_HO]),SampleScaleCond(2).y([breakdown_HO]),'o','color',[1,0.75,0],'MarkerFaceColor','w','LineWidth',1.2);
xlim([-8,1]);
ylim([-1.75,1]);
